Imports Microsoft.VisualBasic

Namespace MyDAO
    Public Class MyDataSortColumn
        Public Column As MyDataExpressionBase
        Public Direction As MyDataSortDirection

        Public Sub New(ByVal columnName As String)
            Me.New(columnName, MyDataSortDirection.Ascending)
        End Sub

        Public Sub New(ByVal columnName As String, ByVal direction As MyDataSortDirection)
            Me.Column = New MyColumnExpression(columnName)
            Me.Direction = direction
        End Sub

        Public Overrides Function ToString() As String
            Return String.Format("{0} {1}", Me.Column, Me.Direction)
        End Function
    End Class
End Namespace
